
Imports System.Data.SqlClient

Namespace _2bMatesSite.BO
	''' <summary>
	''' Represents a static list of the groups's pending members.
	''' </summary>
	Public Class GroupsPendingUsers
		Inherits GroupsUsers
		Public Sub New(ByVal grp As Group)
			MyBase.New(grp)
		End Sub

		Public Sub New(ByVal groupID As Integer)
			MyBase.New(groupID)
		End Sub

		'
		' Private and protected methods
		'

		Protected Overloads Overrides Function GetCommand(ByVal conn As SqlConnection) As SqlCommand
			Dim cmd As New SqlCommand("SELECT * FROM GroupMembers WHERE GroupID=@GroupID AND Status=" + DirectCast(GroupMember.JoinStatus.jsWaitingApproval, Integer))
			cmd.Connection = conn
			cmd.Parameters.Add("@GroupID", groupID)
			Return cmd
		End Function
	End Class
End Namespace






